package Game.Buff;

import org.newdawn.slick.Image;
import org.newdawn.slick.SlickException;

import Game.Objects.GOPlayer;
import Game.Objects.GameObject;
import Game.Objects.Creatures.GOCreature;

/** Debuff Zombie class
 * Description: increase 1 hunger every 1 step
 * @author Aikidos
 */
public class DebuffZombie extends BuffBase {

	public DebuffZombie(BuffManager buffManager) throws SlickException {
		super(buffManager);
		
		setNumOfSteps(100);
		
		_icon = new Image("res/gfx/buff/zombie.png");
	}

	@Override
	public void step() {
		super.step();
		
		GameObject obj = getBuffManager().getOwner();
		
		// Player
		if (obj.isPlayer()) {
			GOPlayer player = (GOPlayer)obj;
			
			player.addHunger(1);
		}
	}
	
}
